package com.soft.model;


public class Store {

	private int id;

	private int userId;

	private int cityId;

	private String storename;

	private String storeAddr;

	private String storeTel;

	private String addtime;

	private User user;

	private City city;
	
	
	
	public int getId() {
		return id;
	}

	public void setId(int id) {
		this.id = id;
	}

	public int getUserId() {
		return userId;
	}

	public void setUserId(int userId) {
		this.userId = userId;
	}

	public int getCityId() {
		return cityId;
	}

	public void setCityId(int cityId) {
		this.cityId = cityId;
	}

	public String getStorename() {
		return storename;
	}

	public void setStorename(String storename) {
		this.storename = storename;
	}

	public String getStoreAddr() {
		return storeAddr;
	}

	public void setStoreAddr(String storeAddr) {
		this.storeAddr = storeAddr;
	}

	public String getStoreTel() {
		return storeTel;
	}

	public void setStoreTel(String storeTel) {
		this.storeTel = storeTel;
	}

	public String getAddtime() {
		if (addtime != null && addtime.contains(".0")) {
			addtime = addtime.replace(".0", "");
		}
		return addtime;
	}

	public void setAddtime(String addtime) {
		this.addtime = addtime;
	}

	public void setCity(City city) {
		this.city = city;
	}

	public City getCity() {
		if(city==null) {
			city =  new City();
		}
		return city;
	}

	public User getUser() {
		if(user==null) {
			user = new User();
		}
		return user;
	}

	public void setUser(User user) {
		this.user = user;
	}

	
}
